<?php echo '<?xml version="1.0" encoding="UTF-8"?>' . "\n"; ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" dir="<?php echo $direction; ?>" lang="<?php echo $lang; ?>" xml:lang="<?php echo $lang; ?>">
<head>
<title id="title">Đá mỹ nghệ - marblevina.com</title>
<?php if ($description) { ?>
<meta name="description" content="<?php echo $description; ?>" />
<?php } ?>
<?php if ($keywords) { ?>
<meta name="keywords" content="<?php echo $keywords; ?>">
<?php } ?>
<base href="<?php echo $base; ?>" />
<?php if ($icon) { ?>
<link href="image/<?php echo $icon; ?>" rel="icon" />
<?php } ?>
<link rel="stylesheet" type="text/css" href="catalog/view/theme/default/stylesheet/stylesheet.css" />
<link rel="stylesheet" type="text/css" href="catalog/view/theme/default/stylesheet/css3.css" />
<link rel="stylesheet" type="text/css" href="catalog/view/theme/default/stylesheet/cart_online.css" />
<link rel="stylesheet" type="text/css" href="catalog/view/theme/default/stylesheet/menu.css" />
<!--[if lt IE 9]>
<link rel="stylesheet" type="text/css" href="catalog/view/theme/default/stylesheet/ie.css" />
<script type="text/javascript" src="catalog/view/javascript/unitpngfix/unitpngfix.js"></script>
<![endif]-->
<?php foreach ($styles as $style) { ?>
<link rel="stylesheet" type="text/css" href="view/stylesheet/<?php echo $style; ?>" />
<?php } ?>
<script type="text/javascript" src="catalog/view/javascript/jquery/jquery-1.6.1.min.js"></script>
<script type="text/javascript" src="catalog/view/javascript/jquery/tab.js"></script>
<?php foreach ($scripts as $script) { ?>
<script type="text/javascript" src="view/javascript/jquery/<?php echo $script; ?>"></script>
<?php } ?>
<script type="text/javascript" src="catalog/view/javascript/easytooltip.js"></script>
<script type="text/javascript" src="catalog/view/javascript/jquery/fancybox/jquery.fancybox-1.3.4.pack.js"></script>
<link rel="stylesheet" type="text/css" href="catalog/view/javascript/jquery/fancybox/jquery.fancybox-1.3.4.css" media="screen" />
<?php echo $google_analytics; ?>
</head>
<body>
<div id="taskbar">
  <div class="taskbar">
	<div class="left">
		Địa chỉ: <span><?php echo $address; ?></span> - Hotline: <span><?php echo $hotline; ?></span>
	</div>
	<div class="right">
		<div class="search">
			<a onclick="moduleSearch();" class="button_search"></a>
			<?php if ($keyword) { ?>
			<input type="text" value="<?php echo $keyword; ?>" id="filter_keyword" />
			<?php } else { ?>
			<input type="text" value="<?php echo $text_keyword; ?>" id="filter_keyword" onclick="this.value = '';" onkeydown="this.style.color = '000000'" style="color: #999;" />
			<?php } ?>
		</div>
		<div class="account" id="showuser">
		<?php if (!$logged) { ?>
			<a href="<?php echo $loginpopup; ?>" class="fancybox"><?php echo $text_login; ?></a>
			<a onclick="location.href='<?php echo $create_account; ?>'"><?php echo $text_create; ?></a>
		<?php }  else { ?>
			<a href="<?php echo $logoutpopup; ?>" class="fancybox"><?php echo $text_logout; ?></a>
			<a href="<?php echo $account; ?>"><?php echo $text_account; ?></a>
		<?php } ?>
		</div>
	</div>
  </div>
</div>
  <div id="header">
	<div class="div1">
		<div class="top">
			<div class="left"><a href="<?php echo $home; ?>"><img style="margin-bottom:5px" height="50" src="<?php echo $logo; ?>" title="<?php echo $store; ?>" alt="<?php echo $store; ?>" /></a>
			</div>
			<div class="right">
				<!-- <div id="cart-online"><div class="middle"></div></div> -->
			</div>
		</div>
	</div>
</div>
<div style="clear:both;"></div>
<div id="contain">

		<div class="">
		<ul id="nav">
		  <li class="<?php if($home_select == 1) { echo 'current';} ?>"><a href="<?php echo $base; ?>"><?php echo $text_home; ?></a></li>
		  <li class="<?php if($gioithieu_select == 1) { echo 'current';} ?>"><a href="<?php echo $gioithieu; ?>"><?php echo $text_gioithieu; ?></a></li>
		  <li class="<?php if($thongtin_select == 1) { echo 'current';} ?>"><a href="<?php echo $thongtin; ?>"><?php echo $text_information; ?></a></li>
		  <li class="<?php if($sanpham_select == 1) { echo 'current';} ?>"><a href="<?php echo $product; ?>"><?php echo $text_sanpham; ?></a></li>
		  <li class="<?php if($news_select == 1) { echo 'current';} ?>"><a href="<?php echo $tintuc; ?>"><?php echo $text_news; ?></a></li>
		  <li class="<?php if($checkout_select == 1) { echo 'current';} ?>"><a href="<?php echo $cart; ?>"><?php echo $text_contact; ?></a></li>
		</ul>
		</div>
<div id="container">
<?php if ($breadcrumbs) { ?>
	<div class="divhead">
	  <div class="bottom">
		<div id="breadcrumb"><ul>
			<?php foreach ($breadcrumbs as $breadcrumb) { ?>
			<li <?php if($breadcrumb['separator']) { echo 'class="next"';} ?>><a href="<?php echo $breadcrumb['href']; ?>"><?php echo $breadcrumb['text']; ?></a></li>
			<?php } ?>
		</ul></div>
	  </div>
	</div>
<?php } ?>	
  <div style="clear:both;"></div>
<script type="text/javascript"><!--
<?php for ($i = 0; $i < sizeof($categories); $i = $i + 1) { ?>
$('#category_<?php echo $i+1; ?> .dropdown_1column').css("width",$('#category_<?php echo $i+1; ?> span.max').width()+30);
<?php } ?>
//--></script>
<script language="javascript">
$('#cart-online .middle').load('index.php?route=common/header/cart');
</script>
<script type="text/javascript"><!--
function getUrlParam(name) {
  var name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]");
  var regexS = "[\\?&]"+name+"=([^&#]*)";
  var regex = new RegExp(regexS);
  var results = regex.exec(window.location.href);
  if (results == null)
	return "";
  else
	return results[1];
}
$(document).ready(function () {
	$('#add_to_cart').replaceWith('<a onclick="" id="add_to_cart" class="button">' + $('#add_to_cart').html() + '</a>');

	$('#add_to_cart').click(function () {
		$.ajax({
			type: 'post',
			url: 'index.php?route=common/header/cart',
			dataType: 'html',
			data: $('#product :input'),
			success: function (html) {
				$('#cart-online .middle').html(html);
			},	
			complete: function () {
				var image = $('#image').offset();
				var cart  = $('#cart-online').offset();
	
				$('#image').before('<img src="' + $('#image').attr('src') + '" id="temp" style="position: absolute; top: ' + image.top + 'px; left: ' + image.left + 'px;" />');
	
				params = {
					top : cart.top + 'px',
					left : cart.left + 'px',
					opacity : 0.0,
					width : $('#cart-online').width(),  
					heigth : $('#cart-online').height()
				};		
	
				$('#temp').animate(params, 'slow', false, function () {
					$('#temp').remove();
				});		
			}			
		});			
	});
	$('.cart_remove').live('dblclick', function () {
		$(this).removeClass('cart_remove').addClass('cart_remove_loading');
		$.ajax({
			type: 'post',
			url: 'index.php?route=common/header/cart',
			dataType: 'html',
			data: 'remove=' + this.id,
			success: function (html) {
				$('#cart-online .middle').html(html);
				if (getUrlParam('route').indexOf('checkout') != -1) {
					window.location.reload();
				}
			}
		});
	});	
});
//--></script>
<script type="text/javascript"><!--
$('.search input').keydown(function(e) {
	if (e.keyCode == 13) {
		moduleSearch();
	}
});
function moduleSearch() {
	pathArray = location.pathname.split( '/' );

	url = 'search/';
		
	var filter_keyword = $('#filter_keyword').attr('value')

	if (filter_keyword) {
		url += 'keyword/' + encodeURIComponent(filter_keyword).replace(/%20/gi, "-") + '/';
	}
	
	location = url;
}
//--></script>
<script type="text/javascript"><!--
$('.switcher').bind('click', function() {
	$(this).find('.option').slideToggle('fast');
});
//--></script>